import instance from "./index.js";
import qs from 'qs'

export function userList(data) {
    return instance.get("users",data);
  }
  export function findUser(data) {
    return instance.get("users?"+qs.stringify(data));
  }
export function addUser(data) {
    return instance.post("users/add",data);
  }

  export function oneUser(data) {
    return instance.get("users/get?userid="+data.userid);
  }

  export function editUser(data) {
    return instance.post("users/edit",data);
  }

  export function delUser(data) {
    return instance.delete("user/delete?id="+data.id);
  }